<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
String name=(String)session.getAttribute("username");


%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'AdminIndex.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
 <%  
  if(name==null){
			out.println("用户名不正确！");
	%>	
		
 <form action="LoginAdminServlet"  method="post">
  <input type="hidden" name=action value=login />
    登录名：<input type=text name="username"><br/>
    密&nbsp;&nbsp;码：<input type=password name="password"><br/>
    <input type="submit" value="登录">
  </form>
  <%
  }
else {
			%>
			<frameset rows="96 , *" frameborder="0">
        <frame src="pages/admin/head.jsp" />
        <frameset cols="168 , *">
                <frame src="pages/admin/siderbar.jsp" />
                <frame src="pages/admin/content_1.jsp" name="showframe" />
        </frameset>        
        <noframes>
        </noframes>
        
</frameset>


<frameset rows="25%,75%">

	<frame src="pages/admin/head.jsp">
	
	<frameset cols="180,*">
	
	  <frame src="pages/admin/siderbar.jsp">
	  <frame src="pages/admin/content_1.jsp" name="showframe">
	
	</frameset>

</frameset> 
			
			
			<%
		}
	%>
	
